
import QtQuick 1.0

Rectangle {
     width: 300; height: 400
     color:"#3E606F"
     focus: true 
     id:containerRect
     Component {
         id: delegate
         Item {
		x:50
		id:rectId
		width: 100; height: containerRect.height
		Column{
		    id : rw
		    spacing: 2
		    y:50; x:10
		    Image { 
			  id: img
			  fillMode: Image.PreserveAspectFit ;
			  smooth: true ;
			  //anchors.horizontalCenter: name.horizontalCenter; 
			  //width: 120; height: 90; 
			  source: image 
			}
		    Text { id: txt; text: name; font.pointSize: 16 ;  wrapMode: Text.WordWrap ; width: 200}
		}
		
		states: State {
		      name: "active"; when: rectId.activeFocus
		      PropertyChanges { target: rw; scale: 1.5 }
		      //PropertyChanges { target: rw; x: 100 }
		  }

		  transitions: Transition {
		      NumberAnimation { properties: "scale"; duration: 100 }
		      //NumberAnimation { properties: "x"; duration: 100 }
		  }
	 }
      }
      ListView {
	      id: list1
	      //width: 200; height: parent.height
	      
	      anchors.horizontalCenter: parent.horizontalCenter
	      anchors.fill: parent
	      focus: true
	      model: PodcastModel {}
	      delegate: delegate	
	      //spacing:100
	      //highlightFollowsCurrentItem: true
	      Component.onCompleted: list1.positionViewAtIndex(- 1, ListView.Visible)
	      
      }
 }